<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>
    <textarea name="" id="" cols="30" rows="10">
        请仔细阅读以下内容
        1.上课不要玩手机
        2.早上好好复习
        3.晚上好好睡觉
    </textarea>
    <br>
    <input type="button" value="请仔细阅读协议(5)" id="btn" disabled>
    <script>
        var btn = document.getElementById("btn");
        var time = 5;

        var timer = setInterval(() => {
            time--;
            if (time <= 0) {
                clearInterval(timer);
                btn.disabled = false;
                btn.value = "同意"
            } else {
                btn.value = `请仔细阅读协议(${time})`
            }

        }, 1000)
    </script>
</body>

</html>